Field of the Invention
The present invention relates to a numerical controller and particularly to a numerical controller capable of a safe and easy reestablishment of a machine coordinate value in the lock state that allows controlling the position of a servo motor.
Description of the Related Art
A machine tool controlled by a numerical controller using an absolute position detector may cause a deviation between a machine coordinate value controlled by the numerical controller and position information of the absolute position detector indicating the position of a servo motor after the power activation.
For example, even in the lock state allowing the position control, when a servo motor is operated by a speed control without a position control, sometimes a machine coordinate value may not be updated. As a result, although the position information of the absolute position detector indicates the correct position of the servo motor, it comes to discord with the machine coordinate value controlled by the numerical controller. In this case, the machine coordinate value needs to be reproduced based on the position information of the absolute position detector.
As a technique that reestablishes a machine coordinate value after the power activation of a numerical controller, a technique in which the numerical controller stops a movable part of the machine tool at any position and reads the numerical value indicated by the absolute position detector, measures the distance between the stop position and the machine origin, and then corrects the numerical value indicated by the absolute position detector based on the measured distance is disclosed in Japanese Patent Application Laid-Open No. 62-095604. In addition, a technique in which the present position is determined when the state of the servo motor is shifted from a free state in which the servomotor position is uncontrollable to a lock state in which the position is controllable is disclosed in Japanese Patent Application Laid-Open No. 2010-225034.
In the prior art disclosed in Japanese Patent Application Laid-Open No. 62-095604 described above, the machine origin is established from the unestablished state of the machine origin and the position information on the absolute position detector side is updated. Therefore, the relationship between the actual machine position and the position information of the absolute position detector is reset. To be specific, when the numerical controller has lost a correct machine coordinate value, a difference is caused between the target machine positions of the movement by the same instruction before and after the update. Thus, the prior art cannot continue the work throughout before and after the update of the position information on the absolute position detector side. Moreover, a manual operation for the movement to the machine origin becomes necessary and requires time.
Furthermore, when the prior art disclosed in Japanese Patent Application Laid-Open No. 2010-225034 is used to establish the machine origin of a gravity axis, since the free state of the servo motor causes a risk of falling of the gravity axis, a device for mechanically fixing the gravity axis becomes necessary and increases the cost. Further, the machine needs to be stopped once, which makes continuous work difficult.